openapi: 3.0.3
info:
  title: Wissen Books
  contact:
    name: Books API
    url: https://github.com/Therad445/Wissen_Books
    email: islamov.radmir@gmail.com
  version: 1.0.0
  description: API Books Backend for Service with Books 
servers:
  - url: /api/v1
tags:
  - name: books
    description: Books service
  - name: genres
    description: Genres service
  - name: authors
    description: Authors service
  - name: publishers
    description: Publishers service
paths:
  /books/books:
    $ref: './books/paths.yaml#/Books'
  /books/books/{id}:
    $ref: './books/paths.yaml#/BooksOne'
  /genres/genres:
    $ref: './genres/paths.yaml#/Genres'
  /genres/genres/{id}:
    $ref: './genres/paths.yaml#/GenresOne'
  /authors/authors:
    $ref: './authors/paths.yaml#/Authors'
  /authors/authors/{id}:
    $ref: './authors/paths.yaml#/AuthorsOne'
  /publishers/publishers:
    $ref: './publishers/paths.yaml#/Publishers'
  /publishers/publishers/{id}:
    $ref: './publishers/paths.yaml#/PublishersOne'
components:
  parameters:
    QueryInclude:
      $ref: './common_parameters.yaml#/QueryInclude'
    PathId:
      $ref: './common_parameters.yaml#/PathId'
  schemas:
    EmptyDataResponse:
      type: object
      properties:
        data:
          type: object
          nullable: true
        meta:
          type: object
      required:
          - data
    PaginationTypeEnum:
      $ref: './common_schemas.yaml#/PaginationTypeEnum'
  responses:
    BadRequest:
      description: Bad Request
      content:
        application/json:
          schema:
            $ref: './errors.yaml#/ErrorResponse'
    NotFound:
      description: Not Found
      content:
        application/json:
          schema:
            $ref: './errors.yaml#/ErrorResponse'
    ServerError:
      description: Internal Server Error
      content:
        application/json:
          schema:
            $ref: './errors.yaml#/ErrorResponse'
